package com.example.demo.service;

import com.example.demo.service.impl.FallBackProductClient;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;

/**
 * Created by zhangjiawen on 2019/5/21.
 */
@FeignClient(name="product-service",fallback = FallBackProductClient.class)
public interface ProductClient {

    @GetMapping("/api/v1/product/getById")
    String findById(@RequestParam(value = "id") int id);

}
